package qeug.shsh.task;

import com.alibaba.fastjson.JSONObject;
import kd.bos.context.RequestContext;
import kd.bos.exception.KDException;
import kd.bos.schedule.executor.AbstractTask;
import qeug.shsh.bpm.Factory.ThirdServiceFactory;
import qeug.shsh.bpm.service.SAPService;

import javax.xml.rpc.ServiceException;
import java.io.IOException;
import java.util.Map;

/**
 * @projectName: qeug-cosmic-root-project
 * @package: qeug.shsh.task
 * @className: SAPBankInfoTaskPlugin
 * @author: wenyx
 * @description: TODO
 * @date: 2025/2/14 16:23
 * @version: 1.0
 */
public class SAPBankInfoTaskPlugin extends AbstractTask {
    @Override
    public void execute(RequestContext requestContext, Map<String, Object> map) throws KDException {
        JSONObject jsonObject = new JSONObject();
        try{
            SAPService sapService = ThirdServiceFactory.createSAPService();
            sapService.getBankInfo(null);
        } catch (ServiceException e) {
            throw new RuntimeException(e);
        } catch (IOException e) {
            throw new RuntimeException(e);
        } catch (Exception e) {
            throw new RuntimeException(e);
        }

    }
}
